package com.example.administrator.myapplication;

import android.content.Intent;
import android.support.v7.app.AppCompatActivity;
import android.os.Bundle;
import android.text.method.PasswordTransformationMethod;
import android.view.View;
import android.view.Window;
import android.widget.Button;
import android.widget.EditText;

public class MainActivity extends AppCompatActivity {

    private EditText zhangHaoText;
    private EditText miMaText;
    private Button zhuCeBtn, wangJiMiMaBtn, dengLuBtn;
    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_main);
        zhangHaoText = (EditText) findViewById(R.id.zhangHaoText);
        miMaText = (EditText) findViewById(R.id.miMaText);
        zhuCeBtn = (Button) findViewById(R.id.zhuCeButton);
        wangJiMiMaBtn = (Button) findViewById(R.id.wangJiMiMaButton);
        dengLuBtn = (Button) findViewById(R.id.dengLuButton);

        miMaText.setTransformationMethod(PasswordTransformationMethod.getInstance());
        zhuCeBtn.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                Intent intent = new Intent();
                intent.setClass(MainActivity.this, ZhuCeActivity.class);
                MainActivity.this.startActivity(intent);
            }
        });

        wangJiMiMaBtn.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                Intent intent = new Intent();
                intent.setClass(MainActivity.this, FindPassword.class);
                MainActivity.this.startActivity(intent);
            }
        });

        dengLuBtn.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                Intent intent = new Intent();
                intent.setClass(MainActivity.this, GeRenZhongXin.class);
                MainActivity.this.startActivity(intent);
            }
        });
    }
}
